<template>
  <div class="banner">
    <van-swipe :autoplay="3000">
      <van-swipe-item v-for="(image, index) in images" :key="index">
        <img class="item-img" v-lazy="image" />
      </van-swipe-item>
    </van-swipe>
  </div>
</template>

<script>
export default {
  name: "HomeBanner",
  data() {
    return {
      images: [
        "https://img.meituan.net/iphoenix/fae12ad6cb45735f4835276ada9cb062167115.jpg.webp",
        "https://p1.meituan.net/iphoenix/3d1f903d47e845f896568b43d3bccc282623564.jpg.webp"
      ]
    };
  }
};
</script>

<style lang="stylus" scoped>
.banner {
  margin-top: 1.12rem;
  // padding: 0;
  border: 0;

  .item-img {
    width: 100%;
    height: 4rem;
  }
}
</style>
